import request from '@/utils/request'

// 查询电-采集器管理列表
export function listElectricityCollector(query) {
  return request({
    url: '/basedata/electricityCollector/list',
    method: 'get',
    params: query
  })
}

// 查询电-采集器管理详细
export function getElectricityCollector(id) {
  return request({
    url: '/basedata/electricityCollector/' + id,
    method: 'get'
  })
}

// 新增电-采集器管理
export function addElectricityCollector(data) {
  return request({
    url: '/basedata/electricityCollector',
    method: 'post',
    data: data
  })
}

// 修改电-采集器管理
export function updateElectricityCollector(data) {
  return request({
    url: '/basedata/electricityCollector',
    method: 'put',
    data: data
  })
}

// 删除电-采集器管理
export function delElectricityCollector(id) {
  return request({
    url: '/basedata/electricityCollector/' + id,
    method: 'delete'
  })
}

export function getCollectorByConcentratorId(id){
  return request({
    url:'/basedata/electricityCollector/getCollectorByConcentratorId/'+id,
    method: 'get',
  })
}
